/*
mixed *customKeys(mapping m)
{
 return efun::keys(m);
}

mixed *keys(mapping m)
{
  mixed *contrast;
  mixed *updateList;
  mixed *list,item;
  int i;
  
  contrast = values(m);
  updateList= allocate(sizeof(contrast));
  list = customKeys(m);
  
  foreach (item in contrast)
  { 
  	mixed customaryKey;
  	
  	if (objectp(item))
  	return efun::keys(m);
  	
  	i = member_array(item,contrast);
  	
  	 foreach (customaryKey in list)
  	 {  	   	
    	if (objectp(list))
    	return efun::keys(m);
  	
    	if (item == m[customaryKey])
     	updateList[i] = customaryKey;
  	 }
  	 
  }
   return updateList;
}*/

string chinese_number(int i)
{
	return CHINESE_D->chinese_number(i);
}

string to_chinese(string str)
{
	return CHINESE_D->chinese(str);
}

int is_chinese(string str)
{
	int i;

	if (strlen(str) < 2 || strlen(str) % 2) return 0;

	for (i = 0; i < strlen(str); i += 2)
	{
		if (str[i] < 176 || str[i] >= 248) return 0;
		if (str[i + 1] < 161 || str[i + 1] == 255) return 0;
	}

	return 1;
}
